package com.atguigu.tingshu.album.rpc;

import com.atguigu.tingshu.album.service.BaseCategoryService;
import com.atguigu.tingshu.common.result.Result;
import com.atguigu.tingshu.model.album.AlbumInfo;
import com.atguigu.tingshu.model.album.BaseCategory3;
import com.atguigu.tingshu.model.album.BaseCategoryView;
import io.swagger.v3.oas.annotations.Operation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/api/album/category/inner")
public class CategoryControllerRpc {

    @Autowired
    BaseCategoryService baseCategoryService;

    @GetMapping("/getCategoryById123rpc/{id}")
    Result<BaseCategoryView> getCategoryById123rpc(@PathVariable Long id){
        BaseCategoryView BaseCategoryView  = baseCategoryService.getCategoryById123rpc(id);
        return Result.ok(BaseCategoryView);
    }


}
